package com.mischa.atc.clearances;

import com.mischa.atc.Clearance;
import com.mischa.atc.Flight;

public class HeadingClearance implements Clearance {
	private float _clearedHeading;
	private boolean _isComplete;
	
	public HeadingClearance(float clearedHeading) {
		_clearedHeading = clearedHeading;
	}
	
	@Override
	public void execute(Flight target) {
		target.turn(_clearedHeading);
		_isComplete = true;
	}

	@Override
	public boolean isComplete() {
		return _isComplete;
	}

}
